package org.ikastola

import ikastola.Constants;

import java.util.Date;

/**
 * Representa descuentos fijos: Becas, por hno menor, etc.
 * 
 * @author mariano
 *
 */
class Discount {

	String name
	Double value
	String description
	Fee fee //sobre que tarifa aplica
	Integer deleted
	Date classCreated
	Date classUpdated
	
	static constraints = {
		name blank:false
		value blank:false
		description blank:false
		deleted blank: false
		classCreated nullable: true
		classUpdated nullable: true
		fee blank: false
	}
	
	def static list() {
		return findAllByDeleted(Constants.NOT_DELETED)
	}
}
